<!DOCTYPE html>

<html>

<head>
    <title></title>
    <script src='../vue.js'></script>
</head>

<body>
    <div id="app-3">
        <div v-bind:class="classObject"></div>
    </div>
    <script>
        var app3 = new Vue({
            el: '#app-3',
            data: {
                isActive: true,
                error: null
            },
            computed: {
                classObject: function () {
                    return {
                        active: this.isActive && !this.error,
                        'text-danger': this.error && this.error.type === 'fatal',
                    }
                }
            }
        });
    </script>
</body>


</html>